package gui;

/**
 * @author Ramy Refky 
 * */
public class WireData {

	ComponentPin firstPin;
	ComponentPin secondPin;
	double offsetTypeA;
	double offsetTypeB;
	double offsetTypeC;
	double offsetTypeD;
	
	/**
	 * Constructor initializes WireData Class to store attributes of wires including offset modification,
	 *  without having to draw them on the WorkArea.
	 * @param FirstPin, SecondPin, offsetTypeA, offsetTypeB, offsetTypeC, offsetTypeD
	 * */
	public WireData(ComponentPin firstPin,ComponentPin secondPin,
			double offsetTypeA,double offsetTypeB,double offsetTypeC,double offsetTypeD){
		this.firstPin=firstPin;
		this.secondPin=secondPin;
		this.offsetTypeA=offsetTypeA;
		this.offsetTypeB=offsetTypeB;
		this.offsetTypeC=offsetTypeC;
		this.offsetTypeD=offsetTypeD;
	}
	/**
	 * Returns the wire's first connected ComponentPin.
	 * @return ComponentPin
	 * */
	public ComponentPin getFirstPin(){
		return firstPin;
	}
	/**
	 * Returns the wire's second connected ComponentPin.
	 * @return ComponentPin
	 * */
	public ComponentPin getSecondPin(){
		return secondPin;
	}
	/**
	 * Returns the offset modification of the wire if the wire is simple (three segments).
	 * By default the offset is 0.5
	 * @return double
	 * */
	public double getOffsetTypeA(){
		return offsetTypeA;
	}
	/**
	 * Returns an offset modification of the wire if it has five segments.
	 * By default the offset is 0.5
	 * @return double
	 * */
	public double getOffsetTypeB(){
		return offsetTypeB;
	}
	/**
	 * Returns an offset modification of the wire if it has five segments.
	 * By default the offset is 0.5
	 * @return double
	 * */
	public double getOffsetTypeC(){
		return offsetTypeC;
	}
	/**
	 * Returns an offset modification of the wire if it has five segments.
	 * By default the offset is 0.5
	 * @return double
	 * */
	public double getOffsetTypeD(){
		return offsetTypeD;
	}
}
